class Vue {
    constructor(obj_instance) {
        this.$data = obj_instance.data;
        Observer(this.$data);
    }
}

function Observer(data_instance) {
    if (!data_instance || typeof obj_instance !== 'object') return;
    Object.keys(data_instance).forEach((key) => {
        let value = data_instance[key];
        Observer(value);
        Object.defineProperty(data_instance, key, {
            enumerable: true,
            configurable: true,
            get() {
                console.log(value);
                return value;
            },
            set(newValue) {
                console.log(newValue, value);
                value = newValue;
            },
        });
    });
}
